import java.io.BufferedReader;
import java.io.FileReader;

/**
 * Created by IntelliJ IDEA.
 * User: rajeev
 * Date: Dec 31, 2009
 * Time: 11:28:31 AM
 * To change this template use File | Settings | File Templates.
 */
public class TestMain {
    public static void main(String[] args) throws Exception {
        StringBuilder sb = new StringBuilder("");
        BufferedReader br = new BufferedReader(new FileReader("testdsd.xml"));
        String line = null;
        while ((line = br.readLine()) != null) {
            sb.append(line);
        }
        br.close();
        Element e = new Element();
        e.parseString(sb.toString());        // now the root is 'e'.
        System.out.println(e.getName());
        for (Element el: e.getChildren()) {
//            System.out.println(el.getName());
//            System.out.println(el.toString());
        }
//        System.out.println(e.getChildren().size());

        RecursiveDescent rd = new RecursiveDescent(e);
        rd.start();

        
    }
}
